\name{treedraw}

\alias{treedraw}

\title{Draw a value from a tree}

\description{
  \code{treedraw} is a function that draws a prediction from a tree using  	the Bayesian bootstrap.
}

\arguments{
  \item{thetree}{A tree that is the output of the \code{tree} function
  from that package.}
  \item{newdata}{A matrix of covariates the predictions.}
  \item{factorvar}{A vector of indicators for which columns of 
  \code{newdata} are factors.}
}

\value{
  Returns a vector of predictions.
}

\author{
  Jerome Reiter and Lane Burgette, Department of Statistical Science,
  Duke University.  \email{jerry@stat.duke.edu, lb131@stat.duke.edu}
}

